<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        // Object.assign(目标对象，源对象，源对象....)将源对象的值赋给目标对象，最后作为返回值返回
        const feifei={
            name:'feifei',
            age:18
        }
        const wenwen={
            run(){
                console.log('文文')
            }
        }
        const yanghui={
            name:'yanghui',//相同的属性会被覆盖
            hobby:["吃,喝,玩,健身"]
        }
        console.log(Object.assign(feifei,wenwen,yanghui));
    </script>
</body>
</html>